Generates a rectangle from two points entered through mouse clicks. Depending on the current object generation mode (first row of icons), the rectangle may be used for the generation of a 2D surface object or a 3D solid object.